package cn.weakup.lambda.funcational;

/**
 * @author Dawn
 * @version 1.0.0
 * @desc
 * @date 2022/5/14
 */
public class Test {
    public static void main(String[] args) {
        String str = handlerString((s) -> s.toUpperCase(), "Dawn");
        System.out.println(str);

        Integer str2 = handlerString2("1", "2", (s1,s2) -> Integer.valueOf(s1) + Integer.valueOf(s2) );
        System.out.println(str2);
    }

    public static String handlerString(MyFunc<String> myFunc, String str){
        return myFunc.getUpCaseValue(str);
    }

    public static Integer handlerString2(String str1, String str2, MyFuncWithReturn<String,Integer> myFunc){
        return myFunc.getAddValue(str1, str2);
    }
}
